<template>
  <div class="app-container">
    <h2 style="text-align: center;">发布新路线</h2>

    <el-steps :active="2" process-status="wait" align-center style="margin-bottom: 40px;">
      <el-step title="填写路线基本信息" />
      <el-step title="编辑路线详情" />
      <el-step title="最终发布" />
    </el-steps>
    <el-form :model="description" label-width="120px" v-show="step==2">
      <!--文本编辑器-->
      <el-form-item label="路线详情" prop="content">
        <mavon-editor v-model="description.content" />
      </el-form-item>
      <el-form-item>
        <el-button @click="previous">上一步</el-button>
      <el-button :disabled="saveBtnDisabled" type="primary" @click="next">下一步</el-button>
      </el-form-item>
    </el-form>
  </div>
</template>

<script>
export default {

  data(){
    return{
      routeId:"",
      saveBtnDisabled: false,
      description: {
        content: ""
      }

    }
  },
  created(){

  },
  methods: {
    //上一步点击事件
    previous(){
      this.$router.push({path:"/route/info/" + this.routeId})
    },
    //下一步点击事件
    next(){
      this.$router.push({path: '/desciption/' + this.routeId})
    }
  }

};
</script>

<style>
</style>